object t3 {
  val numberPrefixMap = Map(
    "139" -> "Guangzhou",
    "138" -> "Shenzhen",
    "137" -> "Beijing"
  )

  def groupByLocation(numbers: List[String]): Map[String, List[String]] = {
    numbers.groupBy { number =>
      numberPrefixMap.getOrElse(number.take(3), "Unknown")
    }
  }
  def main(args: Array[String]): Unit = {
    val mobileNumbers = List("13912345678", "13812345678", "13712345678", "15012345678")
    val grouped = groupByLocation(mobileNumbers)
    println(s"Grouped by location: $grouped")
  }
}
